<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    h1 {
      text-align: center;
      margin: 20px;
    }
    
    .home {
      color: black;
      text-decoration: none;
      position: fixed;
      top: 20px;
      left: 20px;
      font-size: 20px;
    }

    .blog {
      padding: 20px;
      border: 2px solid #ccc;
    }
  </style>
</head>

<body>
  <a class="home" href="./index.html">返回</a>
  <h1 class="title"></h1>
  <div class="blog"></div>
  <script>
    // 获取本地临时字符串
    const html = JSON.parse(sessionStorage.getItem("html"))
    const title = document.querySelector(".title")
    const blog = document.querySelector(".blog")
    title.innerHTML = html.title
    blog.innerHTML = html.blogStr
  </script>
</body>

</html>